#pragma once

#include<stdio.h>
#include<stdlib.h>
#include<assert.h>
#include<stdbool.h>


typedef int HPDataType;

typedef struct Heap
{
	int* a;
	int size;
	int capacity;
}HP;

void HeapInit(HP* hp);
void HeapPush(HP* hp, HPDataType x);
void HeapDestroy(HP* hp);
HPDataType HeapTop(HP* hp);
void swap(HPDataType* n1, HPDataType* n2);
void HeapPrint(HP* hp);
void TopkPrint(int* a, int n, int k);

